require("lualib_bundle");
__TS__SourceMapTraceBack(debug.getinfo(1).short_src, {["4"] = 3,["5"] = 3,["6"] = 3,["7"] = 4,["8"] = 4,["9"] = 6,["10"] = 8,["11"] = 12,["12"] = 12,["13"] = 12,["14"] = 13,["15"] = 14,["16"] = 15,["17"] = 15,["18"] = 16,["19"] = 16,["20"] = 15,["22"] = 15,["23"] = 18,["25"] = 19,["29"] = 22,["30"] = 25,["31"] = 25,["33"] = 26,["34"] = 27,["36"] = 8});
local ____exports = {}
local ____context = require("solar.w3ts.tsx.basic_pragma.hooks.context")
local hookContext = ____context.hookContext
local hookMap = ____context.hookMap
local ____helpers = require("solar.w3ts.tsx.basic_pragma.hooks.helpers")
local argsChanged = ____helpers.argsChanged
require("solar.w3ts.tsx.basic_pragma.hooks.reconcilerHooks")
____exports.useEffect = function(callback, inputs)
    local ____hookContext_currentIndex_0 = hookContext.currentIndex
    hookContext.currentIndex = ____hookContext_currentIndex_0 + 1
    local index = ____hookContext_currentIndex_0
    local hooks = hookMap:get(hookContext.currentInstance)
    local oldState = hooks[index + 1]
    local ____oldState_2 = oldState
    if ____oldState_2 == nil then
        local ____temp_1 = {type = "effect"}
        hooks[index + 1] = ____temp_1
        ____oldState_2 = ____temp_1
    end
    local state = ____oldState_2
    if state.type ~= "effect" then
        error(
            (("Expected an effect hook at index " .. tostring(index)) .. ", got ") .. state.type,
            0
        )
    end
    if not oldState or state.lastInputs and inputs and argsChanged(state.lastInputs, inputs) then
        if state.cleanup then
            state.cleanup()
        end
        state.lastInputs = inputs
        state.cleanup = callback()
    end
end
return ____exports
